"""
数据传输对象（Data Transfer Object）模块：用户信息
"""

from app.common.constants import UserInfoConstants


class UserInfoDto(object):
    """
    用户信息Dto类
    """

    def __init__(self, name, password, _id=0, real_name="", mobile="", avatar="",
                 status=UserInfoConstants.Status.NORMAL.value[0]):
        self.id = _id
        self.name = name
        self.real_name = real_name
        self.password = password
        self.mobile = mobile
        self.avatar = avatar
        self.status = status

    def __str__(self):
        return "({0.id!s}, {0.name!s}, {0.real_name!s}, {0.password!s}, {0.mobile!s}, {0.avatar!s},{0.status!s})".format(
            self)
